#pragma once
#include "freeglut.h"
#include "Hunter.h"
#include "Monster.h"
#include "TextureImage.h"
#include <string>
#include <vector>

using namespace std;

class myApplication
{
public:
	static myApplication* GetInstance()
	{
		static myApplication s_instance;
		return &s_instance;
	}

	bool Init();
	void Exit();

	void SetupRenderContext();
	void GlutReshape(GLsizei w, GLsizei h);
	void GlutMouseClick(int button, int state, int x, int y);
	void GlutMouseMove(int x, int y);
	void GlutKeyboard(unsigned char key, int x, int y);
	void GlutIdle();
	void GlutDisplay();
	void GlutSpecialKey(int key, int x, int y);
	void RenderStringOnScreen(float x, float y, const char* quote);
	bool LoadTGA(TextureImage *texture, char *filename);

private:
	myApplication();
	~myApplication();

	float m_fps;
	float m_worldSizeX;
	float m_worldSizeY;

	void renderTexts(void);

	CHunter *hunter;
	vector<CMonster*> monsters;
	TextureImage HunterTexture[1];
	TextureImage MonsterTexture[1];
	TextureImage Background[1];
};